package com.quanquan.user.service.autoCompute.constant;

import java.util.Arrays;

/**
 *
 */
public interface SymbolConst {

    String
            ADD = "+", SUB = "~", HG = "-", MUL = "*", DIV = "/", COMMA = ",", SELECT = "SELECT",
            LT = "<", L_E = "<=", G_E = ">=", GT = ">", EQ = "=", GROUP_BY = "GROUP BY",
            SPACE = " ", LBRACKET = "(", RBRACKET = ")", CURDATE = "CURDATE", AS = "AS", ON = "ON",
            AND = "AND", OR = "OR",SUM = "SUM", COUNT = "COUNT", WHERE = "WHERE",HAVING = "HAVING", LIKE = "LIKE", FROM = "FROM",
            PER = "%", QUA = "'", YES = "Y", NO = "N", POINT = ".", FALSE = "0", TRUE = "1",
            DAY = "DAY", WEEK = "WEEK", MONTH = "MONTH", QUARTER = "QUARTER", YEAR = "YEAR",
            INNER_JOIN = "INNER JOIN", DISTINCT = "DISTINCT", LIMIT = "LIMIT",
            PUSH_SUCCESS = "push_success_",PUSH_FAILED = "push_failed_", PUSH_TOTAL = "push_total_";
    String[] DATE_RANGE_TYPE = {DAY, WEEK, MONTH, QUARTER, YEAR};

    static boolean isDateRange(String v) {
        return Arrays.asList(DATE_RANGE_TYPE).contains(v);
    }

}
